Skip to content

canvas: expose erwin XML in the Export menu - #61

Merged
dbose merged 1 commit into
mainfrom
feat-erwin-export-canvas
Nov 1, 2026
Merged

dbose merged 1 commit into
mainfrom
feat-erwin-export-canvas

Conversation

@dbose

@dbose dbose commented Nov 1, 2026 •

Copy link
Copy Markdown
Owner

Why

mdl export erwin shipped (PR #60) but CLI-only — the canvas Export dropdown, where users actually export, didn't list it. A format reachable only by typing a CLI command isn't really exposed to users. (Screenshot in the issue showed SQL DDL / Mermaid / DBML / CSV / Data contract / Cypher, but no erwin.)

What

The Export menu is data-driven — it renders whatever GET /api/export returns — so the fix is server-side:

  • Add {"id": "erwin", "label": "erwin XML"} to the advertised format list.
  • Add the erwin branch to /api/export/{fmt}, using the project's export.erwin.naming config (same as the CLI), served as application/xml with a <model>.xml filename.

No canvas rebuild — the existing bundle picks it up from the API; the import side already listed erwin.

Verified live

  • The Export dropdown now shows "erwin XML" (between DBML and CSV) and downloads an XSD-valid <model>.xml.
  • /api/export/erwin → 200, application/xml, Content-Disposition: attachment; filename="<model>.xml", body validates against erwin/ERwinSchema.xsd.

Tests

/api/export lists erwin; /api/export/erwin returns an XML attachment starting with <?xml and Format="erwin". Server suite 233 passed, ruff clean.

The erwin exporter shipped CLI-only (mdl export erwin); the canvas Export dropdown — where
users actually export — didn't offer it, so the feature wasn't discoverable in the UI.

The menu is data-driven (it renders whatever GET /api/export returns), so the fix is server
side: add erwin to the advertised format list and to the /api/export/{fmt} dispatch (using the
project's export.erwin.naming config, same as the CLI; application/xml, .xml filename). No
canvas rebuild needed — the existing bundle picks it up from the API.

Verified live: 'erwin XML' now appears in the Export dropdown and downloads an XSD-valid
document (<model>.xml). Tests: /api/export lists erwin; /api/export/erwin returns an XML
attachment. Server suite 233 passed.
@dbose
dbose merged commit 634f74d into main Nov 1, 2026
2 checks passed
dbose added a commit that referenced this pull request Nov 1, 2026
0.8.0 -> 0.8.1 (patch). Exposes the erwin exporter in the canvas Export dropdown (PR #61) —
UI wiring of the already-shipped 'mdl export erwin' feature, so a patch.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant